function [A, b] = gauss(A, b)
	% triunghiularizare prin eliminare Gauss
	% Intrari :
	% A = matrice sistem
	% b = vector termeni liberi
	% Iesiri :
	% A = matrice sistem superior triunghiular
	% b = termeni liberi sistem triunghiular
	[n, n] = size(A);
	for p= 1 : n - 1
		[ t, A( :, p ) ] = VecG( p, A( :, p ));

		for j = p + 1 :  n
			A( :,j ) = TG( A( :, j ), t, p );
		endfor

		b = TG( b, t, p );
	endfor
endfunction